package market.region.bean;

import java.util.List;

public class MarketRegion {
    int id;
    int pid;
    String name;
    byte type;
    int code;

    List<MarketRegion> children;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getPid() {
        return pid;
    }

    public void setPid(int pid) {
        this.pid = pid;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public byte getType() {
        return type;
    }

    public void setType(byte type) {
        this.type = type;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public List<MarketRegion> getChildren() {
        return children;
    }

    public void setChildren(List<MarketRegion> children) {
        this.children = children;
    }

    public void addChildren(MarketRegion marketRegion){
        children.add(marketRegion);
    }

    public MarketRegion() {

    }

    public MarketRegion(int id, int pid, String name, byte type, int code) {
        this.id = id;
        this.pid = pid;
        this.name = name;
        this.type = type;
        this.code = code;
    }
}
